#include <bits/stdc++.h>

using namespace std;

int xt,yt,xm,ym,cnt;
bool ishorse[30][30];
long long dp[30][30];
int xx[] = {1,1,-1,-1,2,2,-2,-2};
int yy[] = {-2,2,-2,2,-1,1,-1,1};
int main()
{
    cin>>xt>>yt>>xm>>ym;
    ishorse[xm][ym]=1;
    for(int i=0;i<8;i++){
        if((xm+xx[i])>=0&&(xm+xx[i])<=xt&&(ym+yy[i])<=yt&&(ym+yy[i])>=0)
        ishorse[xm+xx[i]][ym+yy[i]]=1;
    }
    dp[0][1]=1;
    for(int i=1;i<=xt+1;i++){
        for(int j=1;j<=yt+1;j++){
            if(!ishorse[i-1][j-1])
            dp[i][j] = dp[i-1][j]+dp[i][j-1];
            else
            dp[i][j] = 0;
        }
    }
    cout<<dp[xt+1][yt+1];
    return 0;
}
